home *** CD-ROM | disk | FTP | other *** search
-
- /*
- There may be additional include files required depending
- upon the compile product you are using. Typical compilers
- include Microsoft C by Microsoft or Turbo C by Boland Int'l.
- */
- #include <stdio.h>
- /*
- float square(float); /* defines a function prototype.
- */
- main()
- {
- float square(), i, j=99.99; /* define square() using vanilla C */
-
- i=square(j);
- printf("The value %.2f squared is: %.2f\n",j,i);
- }
-
- float square(val)
- float val;
- {
- val *= val;
- return(val);
- }
-